package com.gongchang.chouxiang;

public class Zhunmai {
    //
    AbstractMiFac abstractMiFac ;

    public AbstractMiFac getAbstractMiFac() {
        return abstractMiFac;
    }

    public void setAbstractMiFac(AbstractMiFac abstractMiFac) {
        this.abstractMiFac = abstractMiFac;
    }

    public void sellPhone(){
        abstractMiFac.getPhone();
    }

    public void  sellCom(){
        abstractMiFac.getComputer();
    }


    public static void main(String[] args) {
        Zhunmai miZhunmai = new Zhunmai();
        miZhunmai.setAbstractMiFac(new MiFactory());
       miZhunmai.sellCom();
    }
}
